package com.xiang.sql.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableField;
import java.io.Serializable;
import java.util.List;

import io.swagger.annotations.ApiModel;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * 消费单 数据实体
 * 
 * @author mac-xiang
 */
@Data
@EqualsAndHashCode(callSuper = false)
@TableName(value = "`order`", autoResultMap = true)
@ApiModel(value = "消费单 对象", description = "消费单")
public class Order implements Serializable {

  private static final long serialVersionUID = 1L;
  /** 主键ID */
  @TableId(value = "id", type = IdType.ASSIGN_ID)
  public String id;

  /** 商户id */
  @TableField(value = "`gid`", fill = FieldFill.INSERT)
  public String gid;

  /** 创建时间 */
  @TableField(value = "`create_time`", fill = FieldFill.INSERT)
  public Long createTime;

  /** 支付时间 */
  @TableField(value = "`pay_time`")
  public Long payTime;

  /** 发货时间 */
  @TableField(value = "`send_time`")
  public Long sendTime;

  /** 收货时间 */
  @TableField(value = "`recv_time`")
  public Long recvTime;

  /** 收货地址 */
  @TableField(value = "`recv_addr`", fill = FieldFill.INSERT)
  public String recvAddr;
  /** 收货地址 */
  @TableField(value = "`send_des`", fill = FieldFill.INSERT)
  public String sendDes;

  /** 支付id */
  @TableField(value = "`oid`", fill = FieldFill.INSERT)
  public String oid;

  /** 创建用户 */
  @TableField(value = "`create`", fill = FieldFill.INSERT)
  public String create;

  /** 名称 */
  @TableField(value = "`name`", fill = FieldFill.INSERT)
  public String name;

  /** 价格(单位:分) */
  @TableField(value = "`money`", fill = FieldFill.INSERT)
  public Integer money;
  /** 余额抵消(单位:分) */
  @TableField(value = "`balance`", fill = FieldFill.INSERT)
  public Integer balance;

  /** 详细内容 */
  @TableField(value = "`content`", exist = false)
  public List<StockLog> content;

  /** 说明 */
  @TableField(value = "`des`", fill = FieldFill.INSERT)
  public String des;

  /** 奖品id */
  @TableField(value = "`prize`", fill = FieldFill.INSERT)
  public String prize;

  /** 奖品核销商户 */
  @TableField(value = "`prize_group`", fill = FieldFill.INSERT)
  public String prizeGroup;
  /** 奖品核销商户 */
  @TableField(value = "`del`", fill = FieldFill.INSERT)
  public Integer del;

  /** 刷新 */
  @TableField(value = "sx", exist = false)
  public Integer sx;

  public Order() {
  }

  public Order(String id, int del) {
    this.id = id;
    this.del = del;
  }
}